package com.youlu.campus.admin.auth.dto;

import com.youlu.campus.admin.auth.entity.Menu;
import com.youlu.campus.admin.auth.entity.SystemRole;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.util.ArrayList;
import java.util.List;

/**
 * Created by zhuhuaiqi
 */
public class UserInfoDto {

    private String loginName;

    /**
     * 企业域名（冗余）
     */
    private String domain;

    /**
     * 租户ID
     */
    private String comId;
    @NotNull
    @Pattern(regexp = "[\u4e00-\u9fa5a-z0-9A-Z]{1,6}")
    private String realName;
    @NotNull
    @Length(min = 1, max = 16)
    private String nickName;

    /**
     * 用户状态，1，offline；2，online；3，suspend；
     */
    private Integer status;

    private Integer callcenterAuthority;

    private Integer callcenterStatus;

    private List<SystemRole> roles;
    private String id;
    private List<Menu> menus = new ArrayList<Menu>();
    private List<String> menusString = new ArrayList<>();
    private boolean firstLogin = true;
    private List<String> buttonPermissions = new ArrayList<>();

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getLoginName() {
        return loginName;
    }

    public void setLoginName(String loginName) {
        this.loginName = loginName;
    }

    public String getDomain() {
        return domain;
    }

    public void setDomain(String domain) {
        this.domain = domain;
    }

    public String getComId() {
        return comId;
    }

    public void setComId(String comId) {
        this.comId = comId;
    }

    public String getRealName() {
        return realName;
    }

    public void setRealName(String realName) {
        this.realName = realName;
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public List<SystemRole> getRoles() {
        return roles;
    }

    public void setRoles(List<SystemRole> roles) {
        this.roles = roles;
    }

    public Integer getCallcenterAuthority() {
        return callcenterAuthority;
    }

    public void setCallcenterAuthority(Integer callcenterAuthority) {
        this.callcenterAuthority = callcenterAuthority;
    }

    public Integer getCallcenterStatus() {
        return callcenterStatus;
    }

    public void setCallcenterStatus(Integer callcenterStatus) {
        this.callcenterStatus = callcenterStatus;
    }

    public List<Menu> getMenus() {
        return menus;
    }

    public void setMenus(List<Menu> menus) {
        this.menus = menus;
    }

    public List<String> getMenusString() {
        return menusString;
    }

    public void setMenusString(List<String> menusString) {
        this.menusString = menusString;
    }

    public boolean isFirstLogin() {
        return firstLogin;
    }

    public void setFirstLogin(boolean firstLogin) {
        this.firstLogin = firstLogin;
    }

    public List<String> getButtonPermissions() {
        return buttonPermissions;
    }

    public void setButtonPermissions(List<String> buttonPermissions) {
        this.buttonPermissions = buttonPermissions;
    }
}
